package com.th.supcom.pds.outdrugreturnapply.client.widget;

import java.util.Date;

import com.extjs.gxt.ui.client.widget.form.DateField;
import com.extjs.gxt.ui.client.widget.form.DateTimePropertyEditor;
import com.extjs.gxt.ui.client.widget.form.TextField;
import com.th.supcom.pds.common.client.model.CodeConstants;
import com.th.supcom.pds.internal.client.widget.MedicareCardField;

/**
 * 门诊退药文本域组件集合
 * 
 * @author yzhang
 */
public class OutDrugReturnApplyFields
{
    /** 处方号 */
    private TextField <String> m_prescNoField;
    /** 姓名 */
    private TextField <String> m_patiNameField;
    /** 患者ID */
    private TextField <String> m_patiIdField;
    /** 患者ID 用于展示 */
    private TextField <String> m_patiIdWatchField;
    /** 开始时间框 */
    private DateField m_beginField;
    /** 结束时间框 */
    private DateField m_endField;
    /** 患者类型 */
    private TextField <String> m_patiTypeField;
    /** 性别 */
    private TextField <String> m_sexField;
    /** 出生年月 */
    private TextField <Date> m_birthDateField;
    /** 床号 */
    private TextField <String> m_BedNoField;
    /** 入科时间 */
    private TextField <Date> m_deptAdmissionDateField;
    /** 余额 */
    private TextField <Double> m_prepaidField;
    /** 费别名称 */
    private TextField <String> m_chargeTypeName;
    /** 在院科室 */
    private TextField <String> m_deptAdmissionNameField;
    /** 就诊次数 */
    private TextField <Long> m_watchTimes;
    /** 在科天数 */
    private TextField <Integer> m_deptAdmissionDays;
    
    private MedicareCardField m_medicareCardField;
    /**
     * 构造方法
     */
    public OutDrugReturnApplyFields (MedicareCardField medicareCardField)
    {
        m_medicareCardField = medicareCardField;
        InitFields ();
    }

    private void InitFields ()
    {
        m_medicareCardField.setFieldLabel ("刷&nbsp;&nbsp;&nbsp;&nbsp;卡");
        
        m_prescNoField = new TextField <String> ();
        m_prescNoField.setFieldLabel ("处&nbsp;方&nbsp;号");

        m_patiIdField = new TextField <String> ();
        m_patiIdField.setFieldLabel ("患&nbsp;&nbsp;者&nbsp;&nbsp;I&nbsp;&nbsp;D");

        m_beginField = new DateField ();
        m_beginField.setPropertyEditor (new DateTimePropertyEditor (CodeConstants.DATE_FORMAT_YYYY_MM_DD));
        m_beginField.setEditable (false);
        m_beginField.setFieldLabel ("开始");

        m_endField = new DateField ();
        m_endField.setPropertyEditor (new DateTimePropertyEditor (CodeConstants.DATE_FORMAT_YYYY_MM_DD));
        m_endField.setEditable (false);
        m_endField.setFieldLabel ("到");

        m_patiTypeField = new TextField <String> ();
        m_patiTypeField.setFieldLabel ("患者类型");
        m_patiTypeField.setEnabled (false);

        m_patiNameField = new TextField <String> ();
        m_patiNameField.setFieldLabel ("姓&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;名");
        m_patiNameField.setEnabled (false);
        
        m_patiIdWatchField = new TextField <String> ();
        m_patiIdWatchField.setFieldLabel ("患&nbsp;&nbsp;者&nbsp;&nbsp;I&nbsp;&nbsp;D");
        m_patiIdWatchField.setEnabled (false);
        
        m_sexField = new TextField <String> ();
        m_sexField.setFieldLabel ("性&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;别");
        m_sexField.setEnabled (false);
        
        
        m_birthDateField = new TextField <Date> ();
        m_birthDateField.setFieldLabel ("出生年月");
        m_birthDateField.setEnabled (false);
        m_birthDateField.setPropertyEditor (new DateTimePropertyEditor (CodeConstants.DATE_FORMAT_YYYY_MM_DD));
        
        m_prepaidField = new TextField <Double> ();
        m_prepaidField.setFieldLabel ("余&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;额");
        m_prepaidField.setEnabled (false);

        m_chargeTypeName = new TextField <String> ();
        m_chargeTypeName.setFieldLabel ("费&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;别");
        m_chargeTypeName.setEnabled (false);
        
        m_watchTimes = new TextField <Long> ();
        m_watchTimes.setFieldLabel ("就诊次数");
        m_watchTimes.setEnabled (false);
        
        m_deptAdmissionDateField = new TextField <Date> ();
        m_deptAdmissionDateField.setFieldLabel ("就诊时间");
        m_deptAdmissionDateField.setPropertyEditor (new DateTimePropertyEditor (CodeConstants.DATE_FORMAT_YYYY_MM_DD));
        m_deptAdmissionDateField.setEnabled (false);
        
        m_deptAdmissionNameField = new TextField <String> ();
        m_deptAdmissionNameField.setFieldLabel ("就诊科室");
        m_deptAdmissionNameField.setEnabled (false);
        
        m_deptAdmissionDays = new TextField <Integer> ();
        m_deptAdmissionDays.setFieldLabel ("在科天数");
        m_deptAdmissionDays.setEnabled (false);
        
        m_BedNoField = new TextField <String> ();
        m_BedNoField.setFieldLabel ("床&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;号");
        m_BedNoField.setEnabled (false);
        
    }

    /**
     * 获取处方号控件
     * 
     * @return
     */
    public TextField <String> getPrescNoField ()
    {
        return m_prescNoField;
    }

    /**
     * 获取病人姓名控件
     * 
     * @return
     */
    public TextField <String> getPatiNameField ()
    {
        return m_patiNameField;
    }

    /**
     * 获取病人ID控件
     * 
     * @return
     */
    public TextField <String> getPatiIdField ()
    {
        return m_patiIdField;
    }

    /**
     * 获取性别控件
     * 
     * @return
     */
    public TextField <String> getSexField ()
    {
        return m_sexField;
    }

    /**
     * 获取床号
     * 
     * @return
     */
    public TextField <String> getBedNoField ()
    {
        return m_BedNoField;
    }

    /**
     * 获取入科时间
     * 
     * @return
     */
    public TextField <Date> getDeptAdmissionDateField ()
    {
        return m_deptAdmissionDateField;
    }

    /**
     * 获取在院科室
     * 
     * @return
     */
    public TextField <String> getDeptAdmissionNameField ()
    {
        return m_deptAdmissionNameField;
    }

    /**
     * 获取费别
     * 
     * @return
     */
    public TextField <String> getChargeTypeName ()
    {
        return m_chargeTypeName;
    }

    /**
     * 获取就诊次数
     * 
     * @return
     */
    public TextField <Long> getWatchTimes ()
    {
        return m_watchTimes;
    }

    /**
     * 获取入科天数
     * 
     * @return
     */
    public TextField <Integer> getDeptAdmissionDays ()
    {
        return m_deptAdmissionDays;
    }

    /**
     * 获取余额
     * 
     * @return
     */
    public TextField <Double> getPrepaidField ()
    {
        return m_prepaidField;
    }

    /**
     * 获取查询开始时间
     * @return
     */
    public DateField getBeginField ()
    {
        return m_beginField;
    }

    /**
     * 获取出生年月
     * @return
     */
    public TextField <Date> getBirthDateField ()
    {
        return m_birthDateField;
    }

    /**
     * 获取患者ID(用于展示)
     * @return
     */
    public TextField <String> getPatiIdWatchField ()
    {
        return m_patiIdWatchField;
    }

    /**
     * 获取结束时间
     * @return
     */
    public DateField getEndField ()
    {
        return m_endField;
    }

    /**
     * 获取 患者类别
     * @return
     */
    public TextField <String> getPatiTypeField ()
    {
        return m_patiTypeField;
    }

    /**
     * 获取 医保卡
     * @return
     */
    public MedicareCardField getMedicareCardField ()
    {
        return m_medicareCardField;
    }
    
}
